//
//  MLMonthDatePickerButton.h
//  InventoryTool
//
//  Created by molon on 5/26/14.
//  Copyright (c) 2014 Molon. All rights reserved.
//

#import <UIKit/UIKit.h>

@class MLMonthDatePicker;
@class MLMonthDatePickerButton;

@protocol MLMonthDatePickerButtonDelegate <NSObject>

- (void)doneWithDate:(NSDate*)date ofMonthPickerButton:(MLMonthDatePickerButton*)monthPickerButton;

@optional
- (void)resetWithMonthPickerButton:(MLMonthDatePickerButton*)monthPickerButton;

- (void)resignFirstResponderWithMonthPickerButton:(MLMonthDatePickerButton*)monthPickerButton;
- (void)becomeFirstResponderWithMonthPickerButton:(MLMonthDatePickerButton*)monthPickerButton;
- (void)didScrollToDate:(NSDate*)date ofMonthPickerButton:(MLMonthDatePickerButton*)monthPickerButton;

@end

@interface MLMonthDatePickerButton : UIButton

@property (nonatomic, assign) BOOL isCanReset;

@property (nonatomic,weak) id<MLMonthDatePickerButtonDelegate> delegate;
@property (nonatomic,copy) NSString *monthPickerTitle; //toolBar上面的标题

@property (nonatomic,weak,readonly) MLMonthDatePicker *monthPicker; //其实就是inputView

- (void)touchUpInSide;

@end
